<!DOCTYPE html>
<html lang="en" xmlns:th="http://www.thymeleaf.org">
<head>
    <meta charset="UTF-8">
    <title>Title</title>
</head>
<body>
<form action="/teacher/search" method="post">
    <label>Name:</label>
    <input type="text" name="name">
    <label>Age:</label>

    <input type="text" name="age">

    <label>Tel:</label>

    <input type="text" name="tel">
    <input type="submit" value="Search">
</form>
<div>
    <a href="/teacher/create.html">Create</a>
</div>
<table border="1">
    <tr>
        <td>ID</td>
        <td>Name</td>
        <td>Age</td>

        <td>Tel</td>
        <td>Action</td>
    </tr>
    <tr th:each="teacher: ${teacherList}">
        <td th:text="${teacher.id}"></td>
        <td th:text="${teacher.name}"></td>
        <td th:text="${teacher.age}"></td>

        <td th:text="${teacher.tel}"></td>
        <td>
            <a th:href="@{/teacher/edit/{id}(id=${teacher.id})}">Edit</a>
            <a th:href="@{/teacher/delete/{id}(id=${teacher.id})}">Delete</a>
        </td>
    </tr>
</table>

</body>
</html>